package com.example.hibernate.view.util;

import javax.swing.DefaultComboBoxModel;
import javax.swing.JButton;
import javax.swing.JComboBox;
import javax.swing.JLabel;
import javax.swing.JTextField;

public final class WidgetFactory {

	private WidgetFactory() {
	}

	public static JLabel createLabel(String text) {
		return new JLabel(text);
	}

	public static JTextField createTextField() {
		return new JTextField(20);
	}

	public static JButton createButton(String text) {
		return new JButton(text);
	}

	public static <E> JComboBox<E> createComboBox(DefaultComboBoxModel<E> model) {
		return new JComboBox<E>(model);
	}
}
